home *** CD-ROM | disk | FTP | other *** search
/ IRIX Base Documentation 2002 November / SGI IRIX Base Documentation 2002 November.iso / usr / share / catman / g_man / cat3 / ftn / lstwid.z / lstwid
Encoding:
Text File  |  2002-10-03  |  4.0 KB  |  153 lines

  1.  
  2.  
  3.  
  4. llllssssttttwwwwiiiidddd((((3333GGGG))))                                                          llllssssttttwwwwiiiidddd((((3333GGGG))))
  5.  
  6.  
  7.  
  8. NNNNAAAAMMMMEEEE
  9.      llllssssttttwwwwiiiidddd - returns the width of the specified text string
  10.  
  11. FFFFOOOORRRRTTTTRRRRAAAANNNN 77777777 SSSSPPPPEEEECCCCIIIIFFFFIIIICCCCAAAATTTTIIIIOOOONNNN
  12.      iiiinnnntttteeeeggggeeeerrrr****4444 ffffuuuunnnnccccttttiiiioooonnnn ssssttttrrrrwwwwiiiidddd((((ttttyyyyppppeeee,,,, ssssttttrrrr,,,, lllleeeennnnggggtttthhhh))))
  13.      iiiinnnntttteeeeggggeeeerrrr****4444 ttttyyyyppppeeee
  14.      cccchhhhaaaarrrraaaacccctttteeeerrrr****((((****)))) ssssttttrrrr
  15.      iiiinnnntttteeeeggggeeeerrrr****4444 lllleeeennnnggggtttthhhh
  16.  
  17. PPPPAAAARRRRAAAAMMMMEEEETTTTEEEERRRRSSSS
  18.      _t_y_p_e     expects one of the following symbolic constants defined in
  19.               <_g_l/_f_g_l._h>:
  20.  
  21.                          Each character is represented by
  22.                          a single unsigned byte.
  23.                STRB
  24.  
  25.                          Each character is represented by
  26.                          two, consecutive unsigned bytes.
  27.                          The first byte is most
  28.                          significant.
  29.                STR2B
  30.  
  31.  
  32.  
  33.                          Each character is represented by
  34.                          three, consecutive unsigned
  35.                          bytes.  The first byte is most
  36.                          significant.  The last byte is
  37.                          least significant.
  38.                STR3B
  39.  
  40.  
  41.  
  42.  
  43.                          Each character is represented by
  44.                          four, consecutive unsigned bytes.
  45.                          The first byte is most
  46.                          significant.  The last byte is
  47.                          least significant.
  48.                STR4B
  49.  
  50.  
  51.  
  52.  
  53.                          Each character is represented by
  54.                          a 16-bit unsigned integer.
  55.                STR16
  56.  
  57.                          Each character is represented by
  58.                          a 32-bit unsigned integer.
  59.                STR32
  60.  
  61.  
  62.  
  63.      _s_t_r      expects the name of the string whose width is to be computed.
  64.               The contents of the string should be consistent with respect to
  65.               the _t_y_p_e parameter.
  66.  
  67.      _l_e_n_g_t_h   expects the number of characters in the string that is to be
  68.               measured.
  69.  
  70. DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
  71.      llllssssttttwwwwiiiidddd returns the width of a text string in pixels, using the character
  72.      spacing parameters of the current raster font.
  73.  
  74.      Multi-byte types (2B, 3B and 4B) are converted to character values using
  75.      the following formulas for character iiii in unsigned byte-string ssss:
  76.  
  77.        STR2B: (s[2*i]*256) + s[2*i+1]
  78.        STR3B: ((s[3*i]*256) + s[3*i+1])*256 + s[3*i+2]
  79.        STR4B: (((s[4*i]*256) + s[4*i+1])*256) + s[4*i+2])*256 + s[4*i+3]
  80.  
  81.  
  82.  
  83.                                                                         PPPPaaaaggggeeee 1111
  84.  
  85.  
  86.  
  87.  
  88.  
  89.  
  90. llllssssttttwwwwiiiidddd((((3333GGGG))))                                                          llllssssttttwwwwiiiidddd((((3333GGGG))))
  91.  
  92.  
  93.  
  94.      Undefined characters have zero width.
  95.  
  96. SSSSEEEEEEEE AAAALLLLSSSSOOOO
  97.      deflfo, getlwi, lchstr, mapw, mapw2
  98.  
  99. NNNNOOOOTTTTEEEE
  100.      This routine is available only in immediate mode.
  101.  
  102.  
  103.  
  104.  
  105.  
  106.  
  107.  
  108.  
  109.  
  110.  
  111.  
  112.  
  113.  
  114.  
  115.  
  116.  
  117.  
  118.  
  119.  
  120.  
  121.  
  122.  
  123.  
  124.  
  125.  
  126.  
  127.  
  128.  
  129.  
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136.  
  137.  
  138.  
  139.  
  140.  
  141.  
  142.  
  143.  
  144.  
  145.  
  146.  
  147.  
  148.  
  149.                                                                         PPPPaaaaggggeeee 2222
  150.  
  151.  
  152.  
  153.